// receives Intent.ACTION_TIME_TICK and starts schedule check once per minute
package com.bren.android.androidproject;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

public class ScheduleEvent extends BroadcastReceiver{

	public void onReceive(Context context, Intent intent) {
		
		android.util.Log.w("ScheduleEvent","Starting ScheduleService");
		// if scheduling not enabled then we still need to turn back on
		Intent service=new Intent(context, ScheduleService.class);
		context.startService(service);
		// also start map service once per minute
		// it will handle its own frequency if less/more needed
		android.util.Log.w("ScheduleEvent","Starting MapService");
		service=new Intent(context, MapService.class);
		context.startService(service);
	}	
}
